bitkeeper revision 1.306 (3f0ade01zzZKmrmswpUSMGtDKNYM-A)
authorsos22@labyrinth.cl.cam.ac.uk <sos22@labyrinth.cl.cam.ac.uk>
Tue, 8 Jul 2003 15:06:41 +0000 (15:06 +0000)
committersos22@labyrinth.cl.cam.ac.uk <sos22@labyrinth.cl.cam.ac.uk>
Tue, 8 Jul 2003 15:06:41 +0000 (15:06 +0000)
Finish merginf with Keir.

xenolinux-2.4.21-sparse/arch/xeno/drivers/dom0/dom0_core.c
xenolinux-2.4.21-sparse/arch/xeno/drivers/dom0/dom0_memory.c

index c7992095cc638b9703ceb5a7af6fef4eab09834b..adfc9600bab0b4ac5e76d9964cf936307758613e 100644 (file)
@@ -46,7 +46,7 @@ static struct proc_dir_entry *dom0_cmd_intf;
 static struct proc_dir_entry *dom_list_intf;
 
 unsigned long direct_mmap(unsigned long, unsigned long, pgprot_t, int);
-int direct_unmap(unsigned long, unsigned long);
+int direct_unmap(struct mm_struct *, unsigned long, unsigned long);
 
 static ssize_t dom_usage_read(struct file * file, char * buff, size_t size, loff_t * off)
 {
@@ -339,8 +339,8 @@ static int handle_dom0_cmd_unmapdommem(unsigned long data)
   if (copy_from_user(&argbuf, (void *)data, sizeof(argbuf)))
     return -EFAULT;
 
-  return direct_disc_unmap(argbuf.vaddr, argbuf.start_pfn,
-                          argbuf.tot_pages);
+  return direct_unmap(current->mm, argbuf.vaddr,
+                     argbuf.tot_pages << PAGE_SIZE);
 }
 
 static int dom0_cmd_ioctl(struct inode *inode, struct file *file,
index bdc2eb05a4ae6eca2220afd3d7d93ff425ae9624..9d3a06491a85a207cf3b8b4728b586bfc288fc4d 100644 (file)
@@ -85,7 +85,7 @@ static inline int direct_remappmd_range(struct mm_struct *mm, pmd_t * pmd, unsig
 }
 
 /*  Note: this is only safe if the mm semaphore is held when called. */
-int direct_remap_page_range(unsigned long from, unsigned long phys_addr, unsigned long size, pgprot_t prot)
+static int direct_remap_page_range(unsigned long from, unsigned long phys_addr, unsigned long size, pgprot_t prot)
 {
     int error = 0;
     pgd_t * dir;
@@ -120,8 +120,8 @@ int direct_remap_page_range(unsigned long from, unsigned long phys_addr, unsigne
  * used for remapping discontiguous bits of domain's memory, pages to map are
  * found from frame table beginning at the given first_pg index
  */ 
-int direct_remap_disc_page_range(unsigned long from, 
-                                 unsigned long first_pg, int tot_pages, pgprot_t prot)
+static int direct_remap_disc_page_range(unsigned long from, 
+                                       unsigned long first_pg, int tot_pages, pgprot_t prot)
 {
     dom0_op_t dom0_op;
     unsigned long *pfns = (unsigned long *)get_free_page(GFP_KERNEL);
@@ -265,7 +265,7 @@ static inline int direct_zap_pmd_range(mmu_gather_t *tlb, pgd_t * dir,
 /*
  * remove user pages in a given range.
  */
-void direct_zap_page_range(struct mm_struct *mm, unsigned long address, unsigned long size)
+static void direct_zap_page_range(struct mm_struct *mm, unsigned long address, unsigned long size)
 {
     mmu_gather_t *tlb;
     pgd_t * dir;